<div class="modal-header">
    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
    <h5 class="modal-title">配置算法</h5>
</div>

<form id="defaultForm" method="post" class="form-horizontal" action="#">

    <div class="modal-body">
        <div class="form-group">
            <label class="col-lg-3 control-label">是否有效</label>
            <div class="col-lg-5">
                <input id="status" style="margin-top: 5px;" type="checkbox" checked="checked"/>
            </div>
        </div>

        <!--<div class="form-group">-->
            <!--<label class="col-lg-3 control-label">触发条件</label>-->
            <!--<div class="col-lg-5">-->
                <!--<input type="text" class="form-control" name="condition" />-->
            <!--</div>-->
            <!--<a style="margin-left: 10px" onclick="conditionData('/diagnostic/condition_info')">编辑</a>-->
        <!--</div>-->
        <div class="form-group">
            <input type="hidden" name="touchExpression" id="touchExpression">
            <label class="col-lg-3 control-label" >默认触发条件</label>
            <div class="col-lg-5">
                <textarea style="height:60px" class="form-control" id="touchCondition" name="touchCondition" disabled></textarea>
            </div>
            <a style="margin-left: 10px" onclick="conditionData('/project/arithmeticManage/condition_info')">编辑</a>
        </div>

        <div class="form-group">
            <label class="col-lg-3 control-label">工序</label>
            <div class="col-lg-5">
                <textarea type="text" class="form-control" name="process" />
            </div>
            <a style="margin-left: 10px;" href="javascript:void(0)" onclick="processData('/diagnostic/process_list')">编辑</a>
        </div>
    </div>

    <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
        <button type="submit" class="btn btn-primary">保存</button>
    </div>
</form>

<script>
    function processData(url, id) {

        if (id != null) {
            url += "?id=" + id;
        }

        $("#modal_process").modal({
            remote : url
        });
    }

    function conditionData(url, id) {
        if (id != null) {
            url += "?id=" + id;
        }

        $("#modal_condition").modal({
            remote : url
        });
    }

</script>